package com.ttl.web.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.util.Date;

/**
 * 物品表
 *
 * @author 上玄
 */
@Data
@TableName("goods")
public class Goods {
    @TableId(value = "goods_id", type = IdType.AUTO)
    private Integer goodsId;
    private Integer userId;
    // 0:失物1:招领
    private String type;
    private String title;
    private Integer categoryId;
    private String categoryName;
    private String introduce;
    private String address;
    private String userName;
    private String phone;
    private String image;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    private Date createTime;
    private String status; // 0上架1下架
    private String deleteStatus; // 0未删除1已删除
    private String sellStatus; // 0未结束1已结束
    private String setIndex; // 0未设置1设置
    @TableField(exist = false)
    private Integer collectId;
}